package com.wicket.okrbff.biz.service.impl;

import cn.hutool.core.bean.BeanUtil;
import com.wicket.okrbff.biz.service.PostTypeService;
import com.wicket.okrbff.biz.service.dto.common.*;
import com.wicket.okrbff.biz.service.dto.req.*;
import com.wicket.okrbff.biz.service.dto.res.*;
import com.wicket.okrbff.common.util.CommonFunctionHelper;
import com.wicket.okrbff.common.util.RedisUtil;
import com.wicket.okrcomponent.integration.FwCompOffStateClient;
import com.wicket.okrcomponent.integration.dto.QueryStepDetailComBorderReqDto;
import com.wicket.okrcomponent.integration.dto.QueryStepDetailComBorderRespDto;
import com.wicket.okrframework.integration.FwBaseBatchClient;
import com.wicket.okrframework.integration.FwBasePositionClient;
import com.wicket.okrframework.integration.FwBasePostTypeClient;
import com.wicket.okrframework.integration.dto.*;
import org.apache.skywalking.apm.toolkit.trace.Tag;
import org.apache.skywalking.apm.toolkit.trace.Tags;
import org.apache.skywalking.apm.toolkit.trace.Trace;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.stream.Collectors;
import com.wicket.okrbff.common.exception.Assert;

/**
 * @author ：
 * @date ：
 *
 *
 * @version 1.0
 */
@Service
public class PostTypeServiceImpl implements PostTypeService {
    @Resource
    FwBasePostTypeClient postTypeClient;
    @Resource
    FwBasePostTypeClient fwBasePostTypeClient;
    @Resource
    FwBasePositionClient fwBasePositionClient;
    @Resource
    FwCompOffStateClient fwCompOffStateClient;
    @Resource
    FwBaseBatchClient fwBaseBatchClient;
    @Resource
    private RedisUtil redisUtil;

    /**
     * B1-3批量更新岗位类型等级范围（管理）[1299]
     */
    @Trace(operationName = "B1-3批量更新岗位类型等级范围（管理）")
    @Tags({@Tag(key = "参数", value = "arg[0]"),
            @Tag(key = "返回值", value = "returnedObj")})
    @Override
    public BffBatchUpdateStationGradeScopeRespDto batchUpdateStationGradeScope(BffBatchUpdateStationGradeScopeReqDto reqDto) {


        //步骤0: D1-3批量修改岗位类型等级范围 - batchUpdateGradeScope
        BatchUpdateGradeScopeRespDto batchUpdateGradeScopeRespDto = null;
        BatchUpdateGradeScopeReqDto batchUpdateGradeScopeReqDto = new BatchUpdateGradeScopeReqDto();
        if (reqDto != null) {
            batchUpdateGradeScopeReqDto.setPostGradesList(reqDto.getPostGradesList().stream().map(item -> BeanUtil.toBean(item, PostGradesDto.class)).collect(Collectors.toList()));//sourceId:55263_1
            batchUpdateGradeScopeReqDto.setEntityId(reqDto.getEntityId());//sourceId:55266_1
            batchUpdateGradeScopeReqDto.setBatchId(reqDto.getBatchId());//sourceId:55267_1
            batchUpdateGradeScopeReqDto.setStepNameId(reqDto.getStepNameId());//sourceId:56732_1
        }

        /*D1-3批量修改岗位类型等级范围[1298]   */
        batchUpdateGradeScopeRespDto = fwBasePostTypeClient.batchUpdateGradeScope(batchUpdateGradeScopeReqDto).getData();


        BffBatchUpdateStationGradeScopeRespDto retData = new BffBatchUpdateStationGradeScopeRespDto();


        return retData;
    }

    /**
   * B1-3返回上一步调整岗位类型（管理）[1847]
   * gen by moon at 8/10/2022, 3:38:15 AM
   */
    @Trace(operationName = "B1-3返回上一步调整岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffBackToLastStepStationTypeRespDto backToLastStepStationType(BffBackToLastStepStationTypeReqDto reqDto){
      
       
       //步骤0: D1-3批量删除等级范围（处理步骤） - batchDeleteGradeScopeAndDeleteStep
     BatchDeleteGradeScopeAndDeleteStepRespDto batchDeleteGradeScopeAndDeleteStepRespDto = null;
    BatchDeleteGradeScopeAndDeleteStepReqDto batchDeleteGradeScopeAndDeleteStepReqDto=new BatchDeleteGradeScopeAndDeleteStepReqDto();
  if(reqDto!=null){
      batchDeleteGradeScopeAndDeleteStepReqDto.setOrgGradeScopeList(reqDto.getOrgGradeScopeList());//sourceId:56636_1
batchDeleteGradeScopeAndDeleteStepReqDto.setEntityId(reqDto.getEntityId());//sourceId:56742_1
batchDeleteGradeScopeAndDeleteStepReqDto.setStepNameId(reqDto.getStepNameId());//sourceId:56743_1
    }
  
    /*D1-3批量删除等级范围（处理步骤）[1840]   */
    Assert.isNull(batchDeleteGradeScopeAndDeleteStepReqDto.getEntityId(),"B1-3返回上一步调整岗位类型（管理）-D1-3批量删除等级范围（处理步骤）-步骤内容实例ID不能为空",false);
Assert.isNull(batchDeleteGradeScopeAndDeleteStepReqDto.getStepNameId(),"B1-3返回上一步调整岗位类型（管理）-D1-3批量删除等级范围（处理步骤）-当前步骤ID不能为空",false);
      batchDeleteGradeScopeAndDeleteStepRespDto = fwBasePostTypeClient.batchDeleteGradeScopeAndDeleteStep(batchDeleteGradeScopeAndDeleteStepReqDto).getData();
      
      
    
BffBackToLastStepStationTypeRespDto retData = new BffBackToLastStepStationTypeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3批量更新职务级别等级范围（管理）[1834]
   * gen by moon at 8/10/2022, 3:38:06 AM
   */
    @Trace(operationName = "B1-3批量更新职务级别等级范围（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffBatchUpdatePositionGradeScopeRespDto batchUpdatePositionGradeScope(BffBatchUpdatePositionGradeScopeReqDto reqDto){
      
       
       //步骤0: D1-3批量修改职务级别等级范围 - batchUpdatePositionGrade
     BatchUpdatePositionGradeRespDto batchUpdatePositionGradeRespDto = null;
    BatchUpdatePositionGradeReqDto batchUpdatePositionGradeReqDto=new BatchUpdatePositionGradeReqDto();
  if(reqDto!=null){
      batchUpdatePositionGradeReqDto.setOrgGradeScopeList(reqDto.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, OrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:56397_1
batchUpdatePositionGradeReqDto.setBatchId(reqDto.getBatchId());//sourceId:56399_1
    }
  
    /*D1-3批量修改职务级别等级范围[1835]   */
    Assert.isNull(batchUpdatePositionGradeReqDto.getBatchId(),"B1-3批量更新职务级别等级范围（管理）-D1-3批量修改职务级别等级范围-批次ID不能为空",false);
      batchUpdatePositionGradeRespDto = fwBasePostTypeClient.batchUpdatePositionGrade(batchUpdatePositionGradeReqDto).getData();
      
      
    
BffBatchUpdatePositionGradeScopeRespDto retData = new BffBatchUpdatePositionGradeScopeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位类型等级范围列表-第四步（管理）[1833]
   * gen by moon at 8/10/2022, 3:38:04 AM
   */
    @Trace(operationName = "B1-3查询岗位类型等级范围列表-第四步（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryGradeScopeListRespDto queryGradeScopeList(BffQueryGradeScopeListReqDto reqDto){
      
       
       QueryGradeScopeListRespDto queryGradeScopeListRespDto_1 = null;
//步骤0: D1-3查询等级范围列表 - queryGradeScopeList
     QueryGradeScopeListRespDto queryGradeScopeListRespDto = null;
    QueryGradeScopeListReqDto queryGradeScopeListReqDto=new QueryGradeScopeListReqDto();
  queryGradeScopeListReqDto.setTypeCode("JOB_TYPE");//sourceId:56322_1
queryGradeScopeListReqDto.setIsArchive("FALSE");//sourceId:56327_1
queryGradeScopeListReqDto.setArchivngType("NOT_ARCHIVE");//sourceId:56457_1
if(reqDto!=null){
      queryGradeScopeListReqDto.setEntityId(reqDto.getEntityId());//sourceId:56323_1
    }
  
    /*D1-3查询等级范围列表[946]   */
    Assert.isNull(queryGradeScopeListReqDto.getEntityId(),"B1-3查询岗位类型等级范围列表-第四步（管理）-D1-3查询等级范围列表-归属对象实例ID不能为空",false);
Assert.isNull(queryGradeScopeListReqDto.getIsArchive(),"B1-3查询岗位类型等级范围列表-第四步（管理）-D1-3查询等级范围列表-是否存档不能为空",false);
Assert.isNull(queryGradeScopeListReqDto.getArchivngType(),"B1-3查询岗位类型等级范围列表-第四步（管理）-D1-3查询等级范围列表-存档类型不能为空",false);
      queryGradeScopeListRespDto = fwBasePostTypeClient.queryGradeScopeList(queryGradeScopeListReqDto).getData();
      
      queryGradeScopeListRespDto_1 = queryGradeScopeListRespDto;
    
BffQueryGradeScopeListRespDto retData = new BffQueryGradeScopeListRespDto();
  if(queryGradeScopeListRespDto_1!=null){
      retData.setOrgGradeScopeList(queryGradeScopeListRespDto_1.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:56403_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3批量查询职务级别等级范围列表（管理）[1828]
   * gen by moon at 8/10/2022, 3:37:58 AM
   */
    @Trace(operationName = "B1-3批量查询职务级别等级范围列表（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffBatchQueryGradeScopeRespDto batchQueryGradeScope(BffBatchQueryGradeScopeReqDto reqDto){
      
       
       BatchQueryGradeScopeRespDto batchQueryGradeScopeRespDto_1 = null;
//步骤0: D1-3批量查询等级范围列表 - batchQueryGradeScope
     BatchQueryGradeScopeRespDto batchQueryGradeScopeRespDto = null;
    BatchQueryGradeScopeReqDto batchQueryGradeScopeReqDto=new BatchQueryGradeScopeReqDto();
  batchQueryGradeScopeReqDto.setTypeCode("JOB_LEVEL");//sourceId:56354_1
batchQueryGradeScopeReqDto.setIsArchive("FALSE");//sourceId:56356_1
if(reqDto!=null){
      batchQueryGradeScopeReqDto.setOrgGradeScopeList(reqDto.getOrgGradeScopeList());//sourceId:56353_1
    }
  
    /*D1-3批量查询等级范围列表[1829]   */
    
      batchQueryGradeScopeRespDto = fwBasePostTypeClient.batchQueryGradeScope(batchQueryGradeScopeReqDto).getData();
      
      batchQueryGradeScopeRespDto_1 = batchQueryGradeScopeRespDto;
    
BffBatchQueryGradeScopeRespDto retData = new BffBatchQueryGradeScopeRespDto();
  if(batchQueryGradeScopeRespDto_1!=null){
      retData.setOrgGradeScopeList(batchQueryGradeScopeRespDto_1.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:56364_1
    }
  

  
  
return retData;
  }

    /**
     * B1-3查询可存档职务级别条件（管理）
     */
    @Trace(operationName = "B1-3查询可存档职务级别条件（管理）")
    @Tags({@Tag(key = "参数", value = "arg[0]"),
            @Tag(key = "返回值", value = "returnedObj")})
    @Override
    public BffQueryArchivePositionGradeRespDto queryArchivePositionGrade(BffQueryArchivePositionGradeReqDto reqDto) {


        //步骤0: D1-3查询职务列表（边界） - queryPositionListBorder
        QueryPositionListBorderRespDto queryPositionListBorderRespDto = null;
        QueryPositionListBorderReqDto queryPositionListBorderReqDto = new QueryPositionListBorderReqDto();
        queryPositionListBorderReqDto.setIsArchive("FALSE");//sourceId:56021_1
        if (reqDto != null) {
            queryPositionListBorderReqDto.setPositionGradeId(reqDto.getPositionGradeId());//sourceId:56020_1
        }

        /*D1-3查询职务列表（边界）[1653]   */
        queryPositionListBorderRespDto = fwBasePositionClient.queryPositionListBorder(queryPositionListBorderReqDto).getData();


        BffQueryArchivePositionGradeRespDto retData = new BffQueryArchivePositionGradeRespDto();
        retData.setOrgPositionList(queryPositionListBorderRespDto.getOrgPositionList().stream().map(item -> BeanUtil.toBean(item, BffOrgPositionDto.class)).collect(Collectors.toList()));//sourceId:56033_1


        return retData;
    }

    /**
   * B1-3查询岗位类型等级范围列表-第二步（管理）[1812]
   * gen by moon at 8/10/2022, 3:37:56 AM
   */
    @Trace(operationName = "B1-3查询岗位类型等级范围列表-第二步（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStepTwoGradeScopeListRespDto queryStepTwoGradeScopeList(BffQueryStepTwoGradeScopeListReqDto reqDto){
      
       
       QueryGradeScopeListRespDto queryGradeScopeListRespDto_1 = null;
QueryGradeScopeListRespDto queryGradeScopeListRespDto_3 = null;
//步骤0: D1-3查询等级范围列表 - queryGradeScopeList
     QueryGradeScopeListRespDto queryGradeScopeListRespDto = null;
    QueryGradeScopeListReqDto queryGradeScopeListReqDto=new QueryGradeScopeListReqDto();
  queryGradeScopeListReqDto.setTypeCode("JOB_TYPE");//sourceId:55322_1
queryGradeScopeListReqDto.setArchivngType("NOT_ARCHIVE");//sourceId:55367_1
if(reqDto!=null){
      queryGradeScopeListReqDto.setEntityId(reqDto.getEntityId());//sourceId:55323_1
    }
  
    /*D1-3查询等级范围列表（非本次存档）[946]   */
    
      queryGradeScopeListRespDto = fwBasePostTypeClient.queryGradeScopeList(queryGradeScopeListReqDto).getData();
      
      queryGradeScopeListRespDto_1 = queryGradeScopeListRespDto;
    
//步骤1: D1-3查询等级范围列表 - queryGradeScopeList
     QueryGradeScopeListRespDto queryGradeScopeListRespDto_2 = null;
    QueryGradeScopeListReqDto queryGradeScopeListReqDto_1=new QueryGradeScopeListReqDto();
  queryGradeScopeListReqDto_1.setTypeCode("JOB_TYPE");//sourceId:55330_1
queryGradeScopeListReqDto_1.setArchivngType("TOBE_ARCHIVING");//sourceId:55370_1
  
    /*D1-3查询等级范围列表（本次存档）[946]   */
    
      queryGradeScopeListRespDto_2 = fwBasePostTypeClient.queryGradeScopeList(queryGradeScopeListReqDto_1).getData();
      
      queryGradeScopeListRespDto_3 = queryGradeScopeListRespDto_2;
    
BffQueryStepTwoGradeScopeListRespDto retData = new BffQueryStepTwoGradeScopeListRespDto();
  if(queryGradeScopeListRespDto_1!=null){
      retData.setNoArcOrgGradeScopeList(queryGradeScopeListRespDto_1.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffNoArcOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:55524_1
    }
if(queryGradeScopeListRespDto_3!=null){
      retData.setArcOrgGradeScopeList(queryGradeScopeListRespDto_3.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffArcOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:55522_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位类型详情（管理边界）[1804]
   * gen by moon at 8/10/2022, 3:37:49 AM
   */
    @Trace(operationName = "B1-3查询岗位类型详情（管理边界）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStationTypeDetailBorderRespDto queryStationTypeDetailBorder(BffQueryStationTypeDetailBorderReqDto reqDto){
      
       
       QueryStationTypeDetailRespDto queryStationTypeDetailRespDto_1 = null;
//步骤0: D1-3查询岗位类型详情 - queryStationTypeDetail
     QueryStationTypeDetailRespDto queryStationTypeDetailRespDto = null;
    QueryStationTypeDetailReqDto queryStationTypeDetailReqDto=new QueryStationTypeDetailReqDto();
  queryStationTypeDetailReqDto.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:55276_1
if(reqDto!=null){
      queryStationTypeDetailReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:54989_1
    }
  
    /*D1-3查询岗位类型详情[671]   */
    Assert.isNull(queryStationTypeDetailReqDto.getStationTypeId(),"B1-3查询岗位类型详情（管理边界）-D1-3查询岗位类型详情-岗位类型ID不能为空",false);
Assert.isNull(queryStationTypeDetailReqDto.getSubjectLifeCycle(),"B1-3查询岗位类型详情（管理边界）-D1-3查询岗位类型详情-主体生命周期不能为空",false);
      queryStationTypeDetailRespDto = fwBasePostTypeClient.queryStationTypeDetail(queryStationTypeDetailReqDto).getData();
      
      queryStationTypeDetailRespDto_1 = queryStationTypeDetailRespDto;
    
BffQueryStationTypeDetailBorderRespDto retData = new BffQueryStationTypeDetailBorderRespDto();
  if(queryStationTypeDetailRespDto_1!=null){
      retData.setStationTypeId(queryStationTypeDetailRespDto_1.getStationTypeId());//sourceId:55030_1
retData.setStationTypeCode(queryStationTypeDetailRespDto_1.getStationTypeCode());//sourceId:55031_1
retData.setStationTypeNumber(queryStationTypeDetailRespDto_1.getStationTypeNumber());//sourceId:55032_1
retData.setStationTypeName(queryStationTypeDetailRespDto_1.getStationTypeName());//sourceId:55033_1
retData.setStationTypeEnShort(queryStationTypeDetailRespDto_1.getStationTypeEnShort());//sourceId:55034_1
retData.setRankOrderType(queryStationTypeDetailRespDto_1.getRankOrderType());//sourceId:55035_1
retData.setStationGradeRankType(queryStationTypeDetailRespDto_1.getStationGradeRankType());//sourceId:55036_1
retData.setIsManagement(queryStationTypeDetailRespDto_1.getIsManagement());//sourceId:55037_1
retData.setOrderNumber(queryStationTypeDetailRespDto_1.getOrderNumber());//sourceId:55039_1
retData.setIsArchive(queryStationTypeDetailRespDto_1.getIsArchive());//sourceId:55277_1
retData.setOperationInductionId(queryStationTypeDetailRespDto_1.getOperationInductionId());//sourceId:55040_1
retData.setIdCardName(queryStationTypeDetailRespDto_1.getIdCardName());//sourceId:55043_1
retData.setNickName(queryStationTypeDetailRespDto_1.getNickName());//sourceId:55044_1
retData.setOperateTime(queryStationTypeDetailRespDto_1.getOperateTime());//sourceId:55045_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位体系[1798]
   * gen by moon at 8/10/2022, 3:37:47 AM
   */
    @Trace(operationName = "B1-3查询岗位体系")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStationSystemListRespDto queryStationSystemList(BffQueryStationSystemListReqDto reqDto){
      
       
       QueryStationSystemListRespDto queryStationSystemListRespDto_1 = null;
//步骤0: D1-3查询岗位体系 - queryStationSystemList
     QueryStationSystemListRespDto queryStationSystemListRespDto = null;
    QueryStationSystemListReqDto queryStationSystemListReqDto=new QueryStationSystemListReqDto();
  queryStationSystemListReqDto.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:54738_1
if(reqDto!=null){
      queryStationSystemListReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:54737_1
    }
  
    /*D1-3查询岗位体系[1799]   */
    Assert.isNull(queryStationSystemListReqDto.getStationTypeId(),"B1-3查询岗位体系-D1-3查询岗位体系-岗位类型ID不能为空",false);
Assert.isNull(queryStationSystemListReqDto.getSubjectLifeCycle(),"B1-3查询岗位体系-D1-3查询岗位体系-主体生命周期不能为空",false);
      queryStationSystemListRespDto = fwBasePostTypeClient.queryStationSystemList(queryStationSystemListReqDto).getData();
      
      queryStationSystemListRespDto_1 = queryStationSystemListRespDto;
    
BffQueryStationSystemListRespDto retData = new BffQueryStationSystemListRespDto();
  if(queryStationSystemListRespDto_1!=null){
      retData.setOrgPositionGradeList(queryStationSystemListRespDto_1.getOrgPositionGradeList().stream().map(item -> BeanUtil.toBean(item, BffOrgPositionGradeDto.class)).collect(Collectors.toList()));//sourceId:54743_1
retData.setOrgGradeScopeList(queryStationSystemListRespDto_1.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:54744_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询职务级别列表（边界）[1335]
   * gen by moon at 8/10/2022, 3:34:37 AM
   */
    @Trace(operationName = "B1-3查询职务级别列表（边界）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryPositionGradeListBorderRespDto queryPositionGradeListBorder(BffQueryPositionGradeListBorderReqDto reqDto){
      
       
       QueryPositionGradeListBorderRespDto queryPositionGradeListBorderRespDto_1 = null;
//步骤0: D1-3查询职务级别列表（边界） - queryPositionGradeListBorder
     QueryPositionGradeListBorderRespDto queryPositionGradeListBorderRespDto = null;
    QueryPositionGradeListBorderReqDto queryPositionGradeListBorderReqDto=new QueryPositionGradeListBorderReqDto();
  queryPositionGradeListBorderReqDto.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:49240_1
if(reqDto!=null){
      queryPositionGradeListBorderReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:40601_1
    }
  
    /*D1-3查询职务级别列表（边界）[1459]   */
    Assert.isNull(queryPositionGradeListBorderReqDto.getStationTypeId(),"B1-3查询职务级别列表（边界）-D1-3查询职务级别列表（边界）-岗位类型ID不能为空",false);
Assert.isNull(queryPositionGradeListBorderReqDto.getSubjectLifeCycle(),"B1-3查询职务级别列表（边界）-D1-3查询职务级别列表（边界）-主体生命周期不能为空",false);
      queryPositionGradeListBorderRespDto = fwBasePostTypeClient.queryPositionGradeListBorder(queryPositionGradeListBorderReqDto).getData();
      
      queryPositionGradeListBorderRespDto_1 = queryPositionGradeListBorderRespDto;
    
BffQueryPositionGradeListBorderRespDto retData = new BffQueryPositionGradeListBorderRespDto();
  if(queryPositionGradeListBorderRespDto_1!=null){
      retData.setOrgPositionGradeList(queryPositionGradeListBorderRespDto_1.getOrgPositionGradeList().stream().map(item -> BeanUtil.toBean(item, BffOrgPositionGradeDto.class)).collect(Collectors.toList()));//sourceId:35805_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3修改职务级别（管理）[1658]
   * gen by moon at 8/10/2022, 3:36:47 AM
   */
    @Trace(operationName = "B1-3修改职务级别（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffUpdatePositionGradeRespDto updatePositionGrade(BffUpdatePositionGradeReqDto reqDto){
      
       
       //步骤0: D1-3修改职务级别 - updatePositionGrade
     UpdatePositionGradeRespDto updatePositionGradeRespDto = null;
    UpdatePositionGradeReqDto updatePositionGradeReqDto=new UpdatePositionGradeReqDto();
  if(reqDto!=null){
      updatePositionGradeReqDto.setPositionGradeId(reqDto.getPositionGradeId());//sourceId:55976_1
updatePositionGradeReqDto.setPositionGradeNumber(reqDto.getPositionGradeNumber());//sourceId:55977_1
updatePositionGradeReqDto.setPositionGradeName(reqDto.getPositionGradeName());//sourceId:55978_1
updatePositionGradeReqDto.setIsSetGrade(reqDto.getIsSetGrade());//sourceId:55979_1
updatePositionGradeReqDto.setOrderNumber(reqDto.getOrderNumber());//sourceId:55980_1
    }
  
    /*D1-3修改职务级别[1823]   */
    Assert.isNull(updatePositionGradeReqDto.getPositionGradeId(),"B1-3修改职务级别（管理）-D1-3修改职务级别-职务级别ID不能为空",false);
      updatePositionGradeRespDto = fwBasePostTypeClient.updatePositionGrade(updatePositionGradeReqDto).getData();
      
      
    
BffUpdatePositionGradeRespDto retData = new BffUpdatePositionGradeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3修改等级范围（管理）[1655]
   * gen by moon at 8/10/2022, 3:36:41 AM
   */
    @Trace(operationName = "B1-3修改等级范围（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffUpdateGradeScopeRespDto updateGradeScope(BffUpdateGradeScopeReqDto reqDto){
      
       
       //步骤0: D1-3修改等级范围 - updateGradeScope
     UpdateGradeScopeRespDto updateGradeScopeRespDto = null;
    UpdateGradeScopeReqDto updateGradeScopeReqDto=new UpdateGradeScopeReqDto();
  if(reqDto!=null){
      updateGradeScopeReqDto.setGradeScopeId(reqDto.getGradeScopeId());//sourceId:55641_1
updateGradeScopeReqDto.setStationGradeAlias(reqDto.getStationGradeAlias());//sourceId:55642_1
    }
  
    /*D1-3修改等级范围[1815]   */
    
      updateGradeScopeRespDto = fwBasePostTypeClient.updateGradeScope(updateGradeScopeReqDto).getData();
      
      
    
BffUpdateGradeScopeRespDto retData = new BffUpdateGradeScopeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位等级列表（管理）[1654]
   * gen by moon at 8/10/2022, 3:36:39 AM
   */
    @Trace(operationName = "B1-3查询岗位等级列表（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryPostGradesListRespDto queryPostGradesList(BffQueryPostGradesListReqDto reqDto){
      
       
       QueryPostGradesListRespDto queryPostGradesListRespDto_1 = null;
//步骤0: D1-3查询岗位等级列表 - queryPostGradesList
     QueryPostGradesListRespDto queryPostGradesListRespDto = null;
    QueryPostGradesListReqDto queryPostGradesListReqDto=new QueryPostGradesListReqDto();
  if(reqDto!=null){
      queryPostGradesListReqDto.setStationGradeName(reqDto.getStationGradeName());//sourceId:54497_1
    }
  
    /*D1-3查询岗位等级列表[1794]   */
    
      queryPostGradesListRespDto = fwBasePostTypeClient.queryPostGradesList(queryPostGradesListReqDto).getData();
      
      queryPostGradesListRespDto_1 = queryPostGradesListRespDto;
    
BffQueryPostGradesListRespDto retData = new BffQueryPostGradesListRespDto();
  if(queryPostGradesListRespDto_1!=null){
      retData.setPostGradesList(queryPostGradesListRespDto_1.getPostGradesList().stream().map(item -> BeanUtil.toBean(item, BffPostGradesDto.class)).collect(Collectors.toList()));//sourceId:54500_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3初始化岗位类型（管理）[1449]
   * gen by moon at 8/10/2022, 3:35:34 AM
   */
    @Trace(operationName = "B1-3初始化岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffBatchUpdateInitializeGradeScopeRespDto batchUpdateInitializeGradeScope(BffBatchUpdateInitializeGradeScopeReqDto reqDto){
      
       
       //步骤0: D1-3批量删除等级范围（处理步骤） - batchDeleteGradeScopeAndDeleteStep
     BatchDeleteGradeScopeAndDeleteStepRespDto batchDeleteGradeScopeAndDeleteStepRespDto = null;
    BatchDeleteGradeScopeAndDeleteStepReqDto batchDeleteGradeScopeAndDeleteStepReqDto=new BatchDeleteGradeScopeAndDeleteStepReqDto();
  if(reqDto!=null){
      batchDeleteGradeScopeAndDeleteStepReqDto.setOrgGradeScopeList(reqDto.getOrgGradeScopeList());//sourceId:56498_1
batchDeleteGradeScopeAndDeleteStepReqDto.setEntityId(reqDto.getEntityId());//sourceId:56737_1
batchDeleteGradeScopeAndDeleteStepReqDto.setStepNameId(reqDto.getStepNameId());//sourceId:56738_1
    }
  
    /*D1-3批量删除等级范围（处理步骤）[1840]   */
    Assert.isNull(batchDeleteGradeScopeAndDeleteStepReqDto.getEntityId(),"B1-3初始化岗位类型（管理）-D1-3批量删除等级范围（处理步骤）-步骤内容实例ID不能为空",false);
Assert.isNull(batchDeleteGradeScopeAndDeleteStepReqDto.getStepNameId(),"B1-3初始化岗位类型（管理）-D1-3批量删除等级范围（处理步骤）-当前步骤ID不能为空",false);
      batchDeleteGradeScopeAndDeleteStepRespDto = fwBasePostTypeClient.batchDeleteGradeScopeAndDeleteStep(batchDeleteGradeScopeAndDeleteStepReqDto).getData();
      
      
    
BffBatchUpdateInitializeGradeScopeRespDto retData = new BffBatchUpdateInitializeGradeScopeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3删除职务级别（管理）[1332]
   * gen by moon at 8/10/2022, 3:34:33 AM
   */
    @Trace(operationName = "B1-3删除职务级别（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffDeletePositionGradeRespDto deletePositionGrade(BffDeletePositionGradeReqDto reqDto){
      
       
       //步骤0: D1-3删除职务级别 - deletePositionGrade
     DeletePositionGradeRespDto deletePositionGradeRespDto = null;
    DeletePositionGradeReqDto deletePositionGradeReqDto=new DeletePositionGradeReqDto();
  if(reqDto!=null){
      deletePositionGradeReqDto.setPositionGradeId(reqDto.getPositionGradeId());//sourceId:55937_1
    }
  
    /*D1-3删除职务级别[1822]   */
    Assert.isNull(deletePositionGradeReqDto.getPositionGradeId(),"B1-3删除职务级别（管理）-D1-3删除职务级别-职务级别ID不能为空",false);
      deletePositionGradeRespDto = fwBasePostTypeClient.deletePositionGrade(deletePositionGradeReqDto).getData();
      
      
    
BffDeletePositionGradeRespDto retData = new BffDeletePositionGradeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3新增职务级别（管理）[1331]
   * gen by moon at 8/10/2022, 3:34:31 AM
   */
    @Trace(operationName = "B1-3新增职务级别（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffAddPositionGradeRespDto addPositionGrade(BffAddPositionGradeReqDto reqDto){
      
       
       AddPositionGradeRespDto addPositionGradeRespDto_1 = null;
//步骤0: D1-3新增职务级别 - addPositionGrade
     AddPositionGradeRespDto addPositionGradeRespDto = null;
    AddPositionGradeReqDto addPositionGradeReqDto=new AddPositionGradeReqDto();
  if(reqDto!=null){
      addPositionGradeReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:55761_1
addPositionGradeReqDto.setPositionGradeNumber(reqDto.getPositionGradeNumber());//sourceId:55762_1
addPositionGradeReqDto.setPositionGradeName(reqDto.getPositionGradeName());//sourceId:55763_1
addPositionGradeReqDto.setIsSetGrade(reqDto.getIsSetGrade());//sourceId:55764_1
addPositionGradeReqDto.setOrderNumber(reqDto.getOrderNumber());//sourceId:55765_1
addPositionGradeReqDto.setBatchId(reqDto.getBatchId());//sourceId:55766_1
    }
  
    /*D1-3新增职务级别[1816]   */
    Assert.isNull(addPositionGradeReqDto.getStationTypeId(),"B1-3新增职务级别（管理）-D1-3新增职务级别-岗位类型ID不能为空",false);
Assert.isNull(addPositionGradeReqDto.getPositionGradeNumber(),"B1-3新增职务级别（管理）-D1-3新增职务级别-职务级别编号不能为空",false);
Assert.isNull(addPositionGradeReqDto.getPositionGradeName(),"B1-3新增职务级别（管理）-D1-3新增职务级别-职务级别名称不能为空",false);
Assert.isNull(addPositionGradeReqDto.getIsSetGrade(),"B1-3新增职务级别（管理）-D1-3新增职务级别-是否设置等级范围不能为空",false);
Assert.isNull(addPositionGradeReqDto.getOrderNumber(),"B1-3新增职务级别（管理）-D1-3新增职务级别-排序不能为空",false);
Assert.isNull(addPositionGradeReqDto.getBatchId(),"B1-3新增职务级别（管理）-D1-3新增职务级别-批次ID不能为空",false);
      addPositionGradeRespDto = fwBasePostTypeClient.addPositionGrade(addPositionGradeReqDto).getData();
      
      addPositionGradeRespDto_1 = addPositionGradeRespDto;
    
BffAddPositionGradeRespDto retData = new BffAddPositionGradeRespDto();
  if(addPositionGradeRespDto_1!=null){
      retData.setPositionGradeId(addPositionGradeRespDto_1.getPositionGradeId());//sourceId:55773_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位类型列表（边界）[1307]
   * gen by moon at 8/10/2022, 3:34:12 AM
   */
    @Trace(operationName = "B1-3查询岗位类型列表（边界）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStationTypeListBorderRespDto queryStationTypeListBorder(BffQueryStationTypeListBorderReqDto reqDto){
      
       
       QueryStationTypeListBorderRespDto queryStationTypeListBorderRespDto_1 = null;
//步骤0: D1-3查询岗位类型列表（边界） - queryStationTypeListBorder
     QueryStationTypeListBorderRespDto queryStationTypeListBorderRespDto = null;
    QueryStationTypeListBorderReqDto queryStationTypeListBorderReqDto=new QueryStationTypeListBorderReqDto();
  queryStationTypeListBorderReqDto.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:49036_1
queryStationTypeListBorderReqDto.setSpaceId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSpaceId());//CURRENT_SPACEID//sourceId:46044_1
  
    /*D1-3查询岗位类型列表（边界）[670]   */
    Assert.isNull(queryStationTypeListBorderReqDto.getSubjectLifeCycle(),"B1-3查询岗位类型列表（边界）-D1-3查询岗位类型列表（边界）-主体生命周期不能为空",false);
Assert.isNull(queryStationTypeListBorderReqDto.getSpaceId(),"B1-3查询岗位类型列表（边界）-D1-3查询岗位类型列表（边界）-创建于空间ID不能为空",false);
      queryStationTypeListBorderRespDto = fwBasePostTypeClient.queryStationTypeListBorder(queryStationTypeListBorderReqDto).getData();
      
      queryStationTypeListBorderRespDto_1 = queryStationTypeListBorderRespDto;
    
BffQueryStationTypeListBorderRespDto retData = new BffQueryStationTypeListBorderRespDto();
  if(queryStationTypeListBorderRespDto_1!=null){
      retData.setOrgStationTypeList(queryStationTypeListBorderRespDto_1.getOrgStationTypeList().stream().map(item -> BeanUtil.toBean(item, BffOrgStationTypeDto.class)).collect(Collectors.toList()));//sourceId:46056_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询等级范围列表（边界）[1294]
   * gen by moon at 8/10/2022, 3:34:03 AM
   */
    @Trace(operationName = "B1-3查询等级范围列表（边界）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryGradeScopeListBorderRespDto queryGradeScopeListBorder(BffQueryGradeScopeListBorderReqDto reqDto){
      
       
       QueryGradeScopeListBorderRespDto queryGradeScopeListBorderRespDto_1 = null;
//步骤0: D1-3查询等级范围列表（边界） - queryGradeScopeListBorder
     QueryGradeScopeListBorderRespDto queryGradeScopeListBorderRespDto = null;
    QueryGradeScopeListBorderReqDto queryGradeScopeListBorderReqDto=new QueryGradeScopeListBorderReqDto();
  queryGradeScopeListBorderReqDto.setTypeCode("JOB_LEVEL");//sourceId:36489_1
queryGradeScopeListBorderReqDto.setArchivngType("NOT_ARCHIVE");//sourceId:36493_1
if(reqDto!=null){
      queryGradeScopeListBorderReqDto.setEntityId(reqDto.getEntityId());//sourceId:36490_1
    }
  
    /*D1-3查询等级范围列表（边界）[1464]   */
    Assert.isNull(queryGradeScopeListBorderReqDto.getTypeCode(),"B1-3查询等级范围列表（边界）-D1-3查询等级范围列表（边界）-归属对象类型编码不能为空",false);
Assert.isNull(queryGradeScopeListBorderReqDto.getEntityId(),"B1-3查询等级范围列表（边界）-D1-3查询等级范围列表（边界）-归属对象实例ID不能为空",false);
Assert.isNull(queryGradeScopeListBorderReqDto.getArchivngType(),"B1-3查询等级范围列表（边界）-D1-3查询等级范围列表（边界）-存档类型不能为空",false);
      queryGradeScopeListBorderRespDto = fwBasePostTypeClient.queryGradeScopeListBorder(queryGradeScopeListBorderReqDto).getData();
      
      queryGradeScopeListBorderRespDto_1 = queryGradeScopeListBorderRespDto;
    
BffQueryGradeScopeListBorderRespDto retData = new BffQueryGradeScopeListBorderRespDto();
  if(queryGradeScopeListBorderRespDto_1!=null){
      retData.setOrgGradeScopeList(queryGradeScopeListBorderRespDto_1.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:36499_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询职务级别列表（管理）[1289]
   * gen by moon at 8/10/2022, 3:33:58 AM
   */
    @Trace(operationName = "B1-3查询职务级别列表（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryPositionGradeListRespDto queryPositionGradeList(BffQueryPositionGradeListReqDto reqDto){
      
       
       QueryPositionGradeListRespDto queryPositionGradeListRespDto_1 = null;
QueryPositionGradeListRespDto queryPositionGradeListRespDto_3 = null;
//步骤0: D1-3查询职务级别列表 - queryPositionGradeList
     QueryPositionGradeListRespDto queryPositionGradeListRespDto = null;
    QueryPositionGradeListReqDto queryPositionGradeListReqDto=new QueryPositionGradeListReqDto();
  queryPositionGradeListReqDto.setArchivngType("TOBE_ARCHIVING");//sourceId:55830_1
if(reqDto!=null){
      queryPositionGradeListReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:55821_1
    }
  
    /*D1-3查询职务级别列表（想存档）[1817]   */
    
      queryPositionGradeListRespDto = fwBasePostTypeClient.queryPositionGradeList(queryPositionGradeListReqDto).getData();
      
      queryPositionGradeListRespDto_1 = queryPositionGradeListRespDto;
    
//步骤1: D1-3查询职务级别列表 - queryPositionGradeList
     QueryPositionGradeListRespDto queryPositionGradeListRespDto_2 = null;
    QueryPositionGradeListReqDto queryPositionGradeListReqDto_1=new QueryPositionGradeListReqDto();
  queryPositionGradeListReqDto_1.setArchivngType("NOT_ARCHIVE");//sourceId:55908_1
if(reqDto!=null){
      queryPositionGradeListReqDto_1.setStationTypeId(reqDto.getStationTypeId());//sourceId:55907_1
    }
  
    /*D1-3查询职务级别列表（未存档）[1817]   */
    
      queryPositionGradeListRespDto_2 = fwBasePostTypeClient.queryPositionGradeList(queryPositionGradeListReqDto_1).getData();
      
      queryPositionGradeListRespDto_3 = queryPositionGradeListRespDto_2;
    
BffQueryPositionGradeListRespDto retData = new BffQueryPositionGradeListRespDto();
  if(queryPositionGradeListRespDto_3!=null){
      retData.setNoArcpositionGradeList(queryPositionGradeListRespDto_3.getOrgPositionGradeList().stream().map(item -> BeanUtil.toBean(item, BffNoArcpositionGradeDto.class)).collect(Collectors.toList()));//sourceId:55910_1
    }
if(queryPositionGradeListRespDto_1!=null){
      retData.setArcOrgGradeScopeList(queryPositionGradeListRespDto_1.getOrgPositionGradeList().stream().map(item -> BeanUtil.toBean(item, BffArcOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:55911_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位类型等级范围列表-第一步（管理）[1025]
   * gen by moon at 8/10/2022, 3:31:42 AM
   */
    @Trace(operationName = "B1-3查询岗位类型等级范围列表-第一步（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStepOneGradeScopeListRespDto queryStepOneGradeScopeList(BffQueryStepOneGradeScopeListReqDto reqDto){
      
       
       QueryGradeScopeListRespDto queryGradeScopeListRespDto_1 = null;
//步骤0: D1-3查询等级范围列表 - queryGradeScopeList
     QueryGradeScopeListRespDto queryGradeScopeListRespDto = null;
    QueryGradeScopeListReqDto queryGradeScopeListReqDto=new QueryGradeScopeListReqDto();
  queryGradeScopeListReqDto.setTypeCode("JOB_TYPE");//sourceId:54624_1
queryGradeScopeListReqDto.setIsArchive("FALSE");//sourceId:54633_1
if(reqDto!=null){
      queryGradeScopeListReqDto.setEntityId(reqDto.getEntityId());//sourceId:54625_1
    }
  
    /*D1-3查询等级范围列表[946]   */
    
      queryGradeScopeListRespDto = fwBasePostTypeClient.queryGradeScopeList(queryGradeScopeListReqDto).getData();
      
      queryGradeScopeListRespDto_1 = queryGradeScopeListRespDto;
    
BffQueryStepOneGradeScopeListRespDto retData = new BffQueryStepOneGradeScopeListRespDto();
  if(queryGradeScopeListRespDto_1!=null){
      retData.setOrgGradeScopeList(queryGradeScopeListRespDto_1.getOrgGradeScopeList().stream().map(item -> BeanUtil.toBean(item, BffOrgGradeScopeDto.class)).collect(Collectors.toList()));//sourceId:54635_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3取消修订岗位类型（管理）--待[1019]
   * gen by moon at 8/10/2022, 3:31:41 AM
   */
    @Trace(operationName = "B1-3取消修订岗位类型（管理）--待")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffUndoReviseStationTypeRespDto undoReviseStationType(BffUndoReviseStationTypeReqDto reqDto){
      
       
       //步骤0: D1-3取消修订岗位类型 - undoReviseStationType
     UndoReviseStationTypeRespDto undoReviseStationTypeRespDto = null;
    UndoReviseStationTypeReqDto undoReviseStationTypeReqDto=new UndoReviseStationTypeReqDto();
  
  
    /*D1-3取消修订岗位类型[1826]   */
    
      undoReviseStationTypeRespDto = fwBasePostTypeClient.undoReviseStationType(undoReviseStationTypeReqDto).getData();
      
      
    
BffUndoReviseStationTypeRespDto retData = new BffUndoReviseStationTypeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3存档岗位类型（管理）[994]
   * gen by moon at 8/10/2022, 3:31:38 AM
   */
    @Trace(operationName = "B1-3存档岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffArchiveStationTypeRespDto archiveStationType(BffArchiveStationTypeReqDto reqDto){
      
       
       //步骤0: D1-3存档岗位类型 - archiveStationType
     ArchiveStationTypeRespDto archiveStationTypeRespDto = null;
    ArchiveStationTypeReqDto archiveStationTypeReqDto=new ArchiveStationTypeReqDto();
  if(reqDto!=null){
      archiveStationTypeReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:56290_1
    }
  
    /*D1-3存档岗位类型[1670]   */
    Assert.isNull(archiveStationTypeReqDto.getStationTypeId(),"B1-3存档岗位类型（管理）-D1-3存档岗位类型-岗位类型ID不能为空",false);
      archiveStationTypeRespDto = fwBasePostTypeClient.archiveStationType(archiveStationTypeReqDto).getData();
      
      
    
BffArchiveStationTypeRespDto retData = new BffArchiveStationTypeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3修订岗位类型（管理）[687]
   * gen by moon at 8/10/2022, 3:30:06 AM
   */
    @Trace(operationName = "B1-3修订岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffReviseStationTypeRespDto reviseStationType(BffReviseStationTypeReqDto reqDto){
      
       
       ReviseStationTypeRespDto reviseStationTypeRespDto_1 = null;
//步骤0: D2-9查步骤详情(公共)(边界) - queryStepDetailComBorder
     QueryStepDetailComBorderRespDto queryStepDetailComBorderRespDto = null;
    QueryStepDetailComBorderReqDto queryStepDetailComBorderReqDto=new QueryStepDetailComBorderReqDto();
  //queryStepDetailComBorderReqDto.setBizSceneCode();//POST_SYSTEM_SET  TODO ruizhe dong//sourceId:55997_1
queryStepDetailComBorderReqDto.setSubjectLifeCycle("EDITING");//sourceId:56000_1
queryStepDetailComBorderReqDto.setOrderNumber(1L);//CUSTOM_CONVENTION//sourceId:55998_1
  
    /*D2-9查步骤详情(公共)(边界)[1821]   */
    Assert.isNull(queryStepDetailComBorderReqDto.getBizSceneCode(),"B1-3修订岗位类型（管理）-D2-9查步骤详情(公共)(边界)-业务场景标识不能为空",false);
Assert.isNull(queryStepDetailComBorderReqDto.getSubjectLifeCycle(),"B1-3修订岗位类型（管理）-D2-9查步骤详情(公共)(边界)-主体生命周期不能为空",false);
Assert.isNull(queryStepDetailComBorderReqDto.getOrderNumber(),"B1-3修订岗位类型（管理）-D2-9查步骤详情(公共)(边界)-排序不能为空",false);
      queryStepDetailComBorderRespDto = fwCompOffStateClient.queryStepDetailComBorder(queryStepDetailComBorderReqDto).getData();
      
      
    
//步骤1: D1-3修订岗位类型 - reviseStationType
     ReviseStationTypeRespDto reviseStationTypeRespDto = null;
    if(queryStepDetailComBorderRespDto !=null){
          ReviseStationTypeReqDto reviseStationTypeReqDto=new ReviseStationTypeReqDto();
  if(reqDto!=null){
      reviseStationTypeReqDto.setAscriptionObjectId(reqDto.getAscriptionObjectId());//sourceId:55989_1
    }
if(queryStepDetailComBorderRespDto!=null){
      reviseStationTypeReqDto.setStepNameId(queryStepDetailComBorderRespDto.getAssistStepId());//sourceId:56037_1
    }
  
    /*D1-3修订岗位类型[1818]   */
    Assert.isNull(reviseStationTypeReqDto.getAscriptionObjectId(),"B1-3修订岗位类型（管理）-D1-3修订岗位类型-归属对象ID不能为空",false);
Assert.isNull(reviseStationTypeReqDto.getStepNameId(),"B1-3修订岗位类型（管理）-D1-3修订岗位类型-当前步骤ID不能为空",false);
      reviseStationTypeRespDto = fwBasePostTypeClient.reviseStationType(reviseStationTypeReqDto).getData();
      
      reviseStationTypeRespDto_1 = reviseStationTypeRespDto;
           }
    
BffReviseStationTypeRespDto retData = new BffReviseStationTypeRespDto();
  if(reviseStationTypeRespDto_1!=null){
      retData.setBatchId(reviseStationTypeRespDto_1.getBatchId());//sourceId:55992_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3修改岗位类型（管理）[669]
   * gen by moon at 8/10/2022, 3:30:00 AM
   */
    @Trace(operationName = "B1-3修改岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffUpdateStationTypeRespDto updateStationType(BffUpdateStationTypeReqDto reqDto){
      
       
       //步骤0: D1-3修改岗位类型 - updateStationType
     UpdateStationTypeRespDto updateStationTypeRespDto = null;
    UpdateStationTypeReqDto updateStationTypeReqDto=new UpdateStationTypeReqDto();
  if(reqDto!=null){
      updateStationTypeReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:12423_1
updateStationTypeReqDto.setStationTypeName(reqDto.getStationTypeName());//sourceId:12346_1
updateStationTypeReqDto.setStationTypeNumber(reqDto.getStationTypeNumber());//sourceId:12345_1
updateStationTypeReqDto.setStationTypeEnShort(reqDto.getStationTypeEnShort());//sourceId:12347_1
updateStationTypeReqDto.setIsManagement(reqDto.getIsManagement());//sourceId:12343_1
updateStationTypeReqDto.setStationTypeCode(reqDto.getStationTypeCode());//sourceId:55687_1
updateStationTypeReqDto.setRankOrderType(reqDto.getRankOrderType());//sourceId:55688_1
updateStationTypeReqDto.setStationGradeRankType(reqDto.getStationGradeRankType());//sourceId:55689_1
    }
  
    /*D1-3修改岗位类型[672]   */
    Assert.isNull(updateStationTypeReqDto.getStationTypeId(),"B1-3修改岗位类型（管理）-D1-3修改岗位类型-岗位类型ID不能为空",false);
      updateStationTypeRespDto = fwBasePostTypeClient.updateStationType(updateStationTypeReqDto).getData();
      
      
    
BffUpdateStationTypeRespDto retData = new BffUpdateStationTypeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3删除岗位类型（管理）[667]
   * gen by moon at 8/10/2022, 3:29:58 AM
   */
    @Trace(operationName = "B1-3删除岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffDeleteStationTypeRespDto deleteStationType(BffDeleteStationTypeReqDto reqDto){
      
       
       //步骤0: D1-3删除岗位类型 - deleteStationType
     DeleteStationTypeRespDto deleteStationTypeRespDto = null;
    DeleteStationTypeReqDto deleteStationTypeReqDto=new DeleteStationTypeReqDto();
  if(reqDto!=null){
      deleteStationTypeReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:12160_1
    }
  
    /*D1-3删除岗位类型[676]   */
    Assert.isNull(deleteStationTypeReqDto.getStationTypeId(),"B1-3删除岗位类型（管理）-D1-3删除岗位类型-岗位类型ID不能为空",false);
      deleteStationTypeRespDto = fwBasePostTypeClient.deleteStationType(deleteStationTypeReqDto).getData();
      
      
    
BffDeleteStationTypeRespDto retData = new BffDeleteStationTypeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3新增岗位类型（管理）[665]
   * gen by moon at 8/10/2022, 3:29:57 AM
   */
    @Trace(operationName = "B1-3新增岗位类型（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffAddStationTypeRespDto addStationType(BffAddStationTypeReqDto reqDto){
      
       
       AddStationTypeRespDto addStationTypeRespDto_1 = null;
//步骤0: D2-9查步骤详情(公共)(边界) - queryStepDetailComBorder
     QueryStepDetailComBorderRespDto queryStepDetailComBorderRespDto = null;
    QueryStepDetailComBorderReqDto queryStepDetailComBorderReqDto=new QueryStepDetailComBorderReqDto();
  queryStepDetailComBorderReqDto.setBizSceneCode("POST_SYSTEM_SET");//CUSTOM_CONVENTION//sourceId:55967_1
queryStepDetailComBorderReqDto.setSubjectLifeCycle("CURRENTLY_VALID");//sourceId:55968_1
queryStepDetailComBorderReqDto.setOrderNumber(1L);//CUSTOM_CONVENTION//sourceId:55969_1
  
    /*D2-9查步骤详情(公共)(边界)[1821]   */
    Assert.isNull(queryStepDetailComBorderReqDto.getBizSceneCode(),"B1-3新增岗位类型（管理）-D2-9查步骤详情(公共)(边界)-业务场景标识不能为空",false);
Assert.isNull(queryStepDetailComBorderReqDto.getSubjectLifeCycle(),"B1-3新增岗位类型（管理）-D2-9查步骤详情(公共)(边界)-主体生命周期不能为空",false);
Assert.isNull(queryStepDetailComBorderReqDto.getOrderNumber(),"B1-3新增岗位类型（管理）-D2-9查步骤详情(公共)(边界)-排序不能为空",false);
      queryStepDetailComBorderRespDto = fwCompOffStateClient.queryStepDetailComBorder(queryStepDetailComBorderReqDto).getData();
      
      
    
//步骤1: D1-3新增岗位类型 - addStationType
     AddStationTypeRespDto addStationTypeRespDto = null;
    if(queryStepDetailComBorderRespDto !=null){
          AddStationTypeReqDto addStationTypeReqDto=new AddStationTypeReqDto();
  if(reqDto!=null){
      addStationTypeReqDto.setStationTypeName(reqDto.getStationTypeName());//sourceId:12064_1
addStationTypeReqDto.setStationTypeNumber(reqDto.getStationTypeNumber());//sourceId:12063_1
addStationTypeReqDto.setStationTypeEnShort(reqDto.getStationTypeEnShort());//sourceId:12065_1
addStationTypeReqDto.setIsManagement(reqDto.getIsManagement());//sourceId:12062_1
    }
if(queryStepDetailComBorderRespDto!=null){
      addStationTypeReqDto.setStepNameId(queryStepDetailComBorderRespDto.getAssistStepId());//sourceId:55961_1
    }
  
    /*D1-3新增岗位类型[674]   */
    Assert.isNull(addStationTypeReqDto.getStationTypeName(),"B1-3新增岗位类型（管理）-D1-3新增岗位类型-岗位类型名称不能为空",false);
Assert.isNull(addStationTypeReqDto.getStationTypeNumber(),"B1-3新增岗位类型（管理）-D1-3新增岗位类型-岗位类型编号不能为空",false);
Assert.isNull(addStationTypeReqDto.getIsManagement(),"B1-3新增岗位类型（管理）-D1-3新增岗位类型-是否管理岗不能为空",false);
Assert.isNull(addStationTypeReqDto.getStepNameId(),"B1-3新增岗位类型（管理）-D1-3新增岗位类型-当前步骤ID不能为空",false);
      addStationTypeRespDto = fwBasePostTypeClient.addStationType(addStationTypeReqDto).getData();
      
      addStationTypeRespDto_1 = addStationTypeRespDto;
           }
    
BffAddStationTypeRespDto retData = new BffAddStationTypeRespDto();
  if(addStationTypeRespDto_1!=null){
      retData.setStationTypeId(addStationTypeRespDto_1.getStationTypeId());//sourceId:12083_1
retData.setBatchId(addStationTypeRespDto_1.getBatchId());//sourceId:55782_1
retData.setStatusCheckItemId(addStationTypeRespDto_1.getStatusCheckItemId());//sourceId:55783_1
retData.setBehaviorCurrentStepId(addStationTypeRespDto_1.getBehaviorCurrentStepId());//sourceId:55964_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位类型详情（管理）[663]
   * gen by moon at 8/31/2022, 7:28:13 PM
   */
    @Trace(operationName = "B1-3查询岗位类型详情（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStationTypeDetailRespDto queryStationTypeDetail(BffQueryStationTypeDetailReqDto reqDto){
      
       
       QueryStationTypeDetailRespDto queryStationTypeDetailRespDto_1 =null;
QueryBaseBatchDetailRespDto queryBaseBatchDetailRespDto_1 =null;
//步骤0: D1-3查询岗位类型详情 - queryStationTypeDetail
     QueryStationTypeDetailRespDto queryStationTypeDetailRespDto = null;
    QueryStationTypeDetailReqDto queryStationTypeDetailReqDto=new QueryStationTypeDetailReqDto();
  if(reqDto!=null){
      queryStationTypeDetailReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:12200_1
    }
  
    /*D1-3查询岗位类型详情[671]   */
    Assert.isNull(queryStationTypeDetailReqDto.getStationTypeId(),"B1-3查询岗位类型详情（管理）-D1-3查询岗位类型详情-岗位类型ID不能为空",false);
      queryStationTypeDetailRespDto = fwBasePostTypeClient.queryStationTypeDetail(queryStationTypeDetailReqDto).getData();
      
      queryStationTypeDetailRespDto_1 = queryStationTypeDetailRespDto;
    
//步骤1: D1-1查询底层框架服务批次详情 - queryBaseBatchDetail
     QueryBaseBatchDetailRespDto queryBaseBatchDetailRespDto = null;
    if(queryStationTypeDetailRespDto !=null){
          QueryBaseBatchDetailReqDto queryBaseBatchDetailReqDto=new QueryBaseBatchDetailReqDto();
  if(queryStationTypeDetailRespDto!=null){
      queryBaseBatchDetailReqDto.setBatchId(queryStationTypeDetailRespDto.getOrderNumber()!=null?queryStationTypeDetailRespDto.getOrderNumber().toString():null);//sourceId:55216_1
    }
  
    /*D1-1查询底层框架服务批次详情[1805]   */
    Assert.isNull(queryBaseBatchDetailReqDto.getBatchId(),"B1-3查询岗位类型详情（管理）-D1-1查询底层框架服务批次详情-批次ID不能为空",false);
      queryBaseBatchDetailRespDto = fwBaseBatchClient.queryBaseBatchDetail(queryBaseBatchDetailReqDto).getData();
      
      queryBaseBatchDetailRespDto_1 = queryBaseBatchDetailRespDto;
           }
    
BffQueryStationTypeDetailRespDto retData = new BffQueryStationTypeDetailRespDto();
  if(queryStationTypeDetailRespDto_1!=null){
      retData.setStationTypeId(queryStationTypeDetailRespDto_1.getStationTypeId());//sourceId:54953_1
retData.setStationTypeName(queryStationTypeDetailRespDto_1.getStationTypeName());//sourceId:54957_1
retData.setStationTypeNumber(queryStationTypeDetailRespDto_1.getStationTypeNumber());//sourceId:54956_1
retData.setStationTypeCode(queryStationTypeDetailRespDto_1.getStationTypeCode());//sourceId:54954_1
retData.setStationTypeEnShort(queryStationTypeDetailRespDto_1.getStationTypeEnShort());//sourceId:54959_1
retData.setRankOrderType(queryStationTypeDetailRespDto_1.getRankOrderType());//sourceId:54958_1
retData.setStationGradeRankType(queryStationTypeDetailRespDto_1.getStationGradeRankType());//sourceId:54975_1
retData.setIsManagement(queryStationTypeDetailRespDto_1.getIsManagement());//sourceId:54955_1
retData.setOrderNumber(queryStationTypeDetailRespDto_1.getOrderNumber());//sourceId:54960_1
retData.setOperationInductionId(queryStationTypeDetailRespDto_1.getOperationInductionId());//sourceId:54962_1
retData.setOperationName(queryStationTypeDetailRespDto_1.getIdCardName());//sourceId:54966_1
retData.setOperationNickName(queryStationTypeDetailRespDto_1.getNickName());//sourceId:54967_1
retData.setOperateTime(queryStationTypeDetailRespDto_1.getOperateTime());//sourceId:54968_1
    }
if(queryBaseBatchDetailRespDto_1!=null){
      retData.setIsFirst(queryBaseBatchDetailRespDto_1.getIsFirst());//sourceId:55222_1
retData.setSubjectLifeCycle(queryBaseBatchDetailRespDto_1.getSubjectLifeCycle());//sourceId:55223_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3查询岗位类型列表[660]
   * gen by moon at 8/10/2022, 3:29:49 AM
   */
    @Trace(operationName = "B1-3查询岗位类型列表")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryStationTypeListRespDto queryStationTypeList(BffQueryStationTypeListReqDto reqDto){
      
       
       QueryStationTypeListRespDto queryStationTypeListRespDto_1 = null;
//步骤0: D1-3查询岗位类型列表 - queryStationTypeList
     QueryStationTypeListRespDto queryStationTypeListRespDto = null;
    QueryStationTypeListReqDto queryStationTypeListReqDto=new QueryStationTypeListReqDto();
  if(reqDto!=null){
      queryStationTypeListReqDto.setIsArchive(reqDto.getIsArchive());//sourceId:54781_1
    }
  
    /*D1-3查询岗位类型列表[1458]   */
    Assert.isNull(queryStationTypeListReqDto.getIsArchive(),"B1-3查询岗位类型列表-D1-3查询岗位类型列表-是否存档不能为空",false);
      queryStationTypeListRespDto = fwBasePostTypeClient.queryStationTypeList(queryStationTypeListReqDto).getData();
      
      queryStationTypeListRespDto_1 = queryStationTypeListRespDto;
    
BffQueryStationTypeListRespDto retData = new BffQueryStationTypeListRespDto();
  if(queryStationTypeListRespDto_1!=null){
      retData.setOrgStationTypeList(queryStationTypeListRespDto_1.getOrgStationTypeList().stream().map(item -> BeanUtil.toBean(item, BffOrgStationTypeDto.class)).collect(Collectors.toList()));//sourceId:54782_1
    }
  

  
  
return retData;
  }

    /**
   * B1-3批量存档等级范围(管理）[1448]
   * gen by moon at 8/10/2022, 3:35:32 AM
   */
    @Trace(operationName = "B1-3批量存档等级范围(管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffBatchArchiveGradeScopeRespDto batchArchiveGradeScope(BffBatchArchiveGradeScopeReqDto reqDto){
      
       
       BffBatchArchiveGradeScopeRespDto retData = new BffBatchArchiveGradeScopeRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3批量改岗位等级（管理）[1300]
   * gen by moon at 8/10/2022, 3:34:05 AM
   */
    @Trace(operationName = "B1-3批量改岗位等级（管理）")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffBatchUpdatePostGradesRespDto batchUpdatePostGrades(BffBatchUpdatePostGradesReqDto reqDto){
      
       
       BffBatchUpdatePostGradesRespDto retData = new BffBatchUpdatePostGradesRespDto();
  
  

  
  
return retData;
  }

    /**
   * B1-3查询管理模式职务级别列表(管理)(边界)[1675]
   * gen by moon at 8/10/2022, 3:36:54 AM
   */
    @Trace(operationName = "B1-3查询管理模式职务级别列表(管理)(边界)")
    @Tags({@Tag(key = "参数",value = "arg[0]"),
            @Tag(key = "返回值",value = "returnedObj")})
  @Override
  public BffQueryPositionGradeMgtListBorderRespDto queryPositionGradeMgtListBorder(BffQueryPositionGradeMgtListBorderReqDto reqDto){
      
       
       QueryPositionGradeListRespDto queryPositionGradeListRespDto_1 = null;
//步骤0: D1-3查询职务级别列表 - queryPositionGradeList
     QueryPositionGradeListRespDto queryPositionGradeListRespDto = null;
    QueryPositionGradeListReqDto queryPositionGradeListReqDto=new QueryPositionGradeListReqDto();
  queryPositionGradeListReqDto.setIsArchive("FALSE");//sourceId:56059_1
queryPositionGradeListReqDto.setArchivngType("NOT_ARCHIVE");//sourceId:56296_1
if(reqDto!=null){
      queryPositionGradeListReqDto.setStationTypeId(reqDto.getStationTypeId());//sourceId:56058_1
    }
  
    /*D1-3查询职务级别列表[1817]   */
    Assert.isNull(queryPositionGradeListReqDto.getStationTypeId(),"B1-3查询管理模式职务级别列表(管理)(边界)-D1-3查询职务级别列表-岗位类型ID不能为空",false);
      queryPositionGradeListRespDto = fwBasePostTypeClient.queryPositionGradeList(queryPositionGradeListReqDto).getData();
      
      queryPositionGradeListRespDto_1 = queryPositionGradeListRespDto;
    
BffQueryPositionGradeMgtListBorderRespDto retData = new BffQueryPositionGradeMgtListBorderRespDto();
  if(queryPositionGradeListRespDto_1!=null){
      retData.setOrgPositionGradeList(queryPositionGradeListRespDto_1.getOrgPositionGradeList().stream().map(item -> BeanUtil.toBean(item, BffOrgPositionGradeDto.class)).collect(Collectors.toList()));//sourceId:56088_1
    }
  

  
  
return retData;
  }
    //
}
